<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8">
    <title>IOT LAO WANG</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="stylesheet" type="text/css" href="stylesheet.css">
  </head>
  <body>
    <h1>Date and Time</h1>
    <p id="dateTime"></p>
    <script>
      // var todays_date = new Date();
      // document.getElementById("dateTime").innerHTML = todays_date;
      function time() {
				var vWeek, vWeek_s, vDay;
				vWeek = ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"];
				var date =  new Date();
				year = date.getFullYear();
				month = date.getMonth() + 1;
				day = date.getDate();
				hours = date.getHours();
				minutes = date.getMinutes();
				seconds = date.getSeconds();
				vWeek_s = date.getDay();
				document.getElementById("dateTime").innerHTML = year + "年" + month + "月" + day + "日" + "\t" + hours + ":" + minutes + ":" + seconds + "\t" + vWeek[vWeek_s];
			};
			setInterval("time()", 1000);
    </script>
  </body>
</html>